class Person {
  public readonly name: string;
  age: number;
  constructor(name: string, age: number) {
    this.name = name
    this.age = age
  }

  speak() {
    console.log(`我叫${this.name},今年${this.age}岁`)
  }
}

class Student extends Person {
  constructor(name: string, age: number) {
    super(name, age)
  }

  study() {
    console.log(this.name, '学习')
  }
}

export {}